Computing Register with Non-Volatile-Logic Data Storage

ABSTRACT

A digital system includes a non-volatile calculating register having a set of latches configured to perform a calculation. A set of non-volatile storage cells is coupled to the set of latches. Access detection logic is coupled to the calculating register and is operable to initiate a calculation of a next value by the calculating register each time the calculating register is accessed by an accessing module. The access detection logic is operable to cause the next value to be stored in the set of non-volatile storage cells at the completion of the calculation as an atomic transaction. After a power loss or other restore event, the contents of the calculating register may be restored from the non-volatile storage cells.

CLAIM OF PRIORITY UNDER 35 U.S.C. 119(e)

The present application claims priority to and incorporates by referenceU.S. Provisional Application No. 62/028,119 (attorney docket TI-75056PS)filed Jul. 23, 2014, entitled “NON-DISRUPTIVE LINEAR FEEDBACK SHIFTREGISTER AND UP-/DOWN-COUNTER WITH NON-VOLATILE-LOGIC (NVL) BASED DATASTORAGE.”

FIELD OF THE INVENTION

This invention generally relates to nonvolatile memory cells and theiruse in a system, and in particular, in combination with a computingregister to provide a nonvolatile logic module.

BACKGROUND OF THE INVENTION

Many portable electronic devices such as cellular phones, digitalcameras/camcorders, personal digital assistants, laptop computers, andvideo games operate on batteries. During periods of inactivity thedevice may not need to perform processing operations and may be placedin a power-down or standby power mode to conserve power. Power providedto a portion of the logic within the electronic device may be turned offin a low power standby power mode. However, presence of leakage currentduring the standby power mode represents a challenge for designingportable, battery operated devices. Data retention circuits such asflip-flops and/or latches within the device may be used to store stateinformation for later use prior to the device entering the standby powermode. The data retention latch, which may also be referred to as ashadow latch or a balloon latch, is typically powered by a separate‘always on’ power supply.

A known technique for reducing leakage current during periods ofinactivity utilizes multi-threshold CMOS (MTCMOS) technology toimplement a shadow latch. In this approach, the shadow latch utilizesthick gate oxide transistors and/or high threshold voltage (V_(t))transistors to reduce the leakage current in standby power mode. Theshadow latch is typically detached from the rest of the circuit duringnormal operation (e.g., during an active power mode) to maintain systemperformance. To retain data in a ‘master-slave’ flip-flop topology, athird latch, e.g., the shadow latch, may be added to the master latchand the slave latch for the data retention. In other cases, the slavelatch may be configured to operate as the retention latch during lowpower operation. However, some power is still required to retain thesaved state. For example, see U.S. Pat. No. 7,639,056, “Ultra Low AreaOverhead Retention Flip-Flop for Power-Down Applications”.

Some systems are now operated on harvested energy, in which case theymay be active when power is available and then turn off when no power isavailable. Energy harvesting, also known as power harvesting or energyscavenging, is the process by which energy is derived from externalsources, captured, and stored for small, wireless autonomous devices,such as those used in wearable electronics and wireless sensor networks.Harvested energy may be derived from various sources, such as: solarpower, thermal energy, wind energy, salinity gradients and kineticenergy, etc. However, typical energy harvesters provide a very smallamount of power for low-energy electronics. The energy source for energyharvesters may be present as ambient background and is available foruse. For example, temperature gradients exist from the operation of acombustion engine; there is a large amount of electromagnetic energy inthe environment because of radio and television broadcasting, etc.

System on Chip (SoC) is now a commonly used concept; the basic approachis to integrate more and more functionality into a given device. Thisintegration can take the form of either hardware or solution software.Performance gains are traditionally achieved by increased clock ratesand more advanced process nodes. Many SoC designs pair a microprocessorcore, or multiple cores, with various peripheral devices and memorycircuits.

BRIEF DESCRIPTION OF THE DRAWINGS

Particular embodiments in accordance with the invention will now bedescribed, by way of example only, and with reference to theaccompanying drawings:

FIG. 1 is a block diagram of an example SoC which includes an embodimentof the invention;

FIGS. 2 and 3 are more detailed block diagrams of embodiments of anon-volatile computing register for the SoC of FIG. 1;

FIG. 4 is a plot illustrating polarization hysteresis exhibited by aferroelectric capacitor;

FIG. 5 is a more detailed circuit diagram of an embodiment of anon-volatile computing register;

FIG. 6 is a functional block diagram of a portion of a system on chip(SoC) 100 that includes an embodiment of the invention; and

FIG. 7 is a flow chart illustrating operation of a non-volatilecomputing circuit that performs atomic backup transactions.

Other features of the present embodiments will be apparent from theaccompanying drawings and from the detailed description that follows.

DETAILED DESCRIPTION OF EMBODIMENTS OF THE INVENTION

Specific embodiments of the invention will now be described in detailwith reference to the accompanying figures. Like elements in the variousfigures are denoted by like reference numerals for consistency. In thefollowing detailed description of embodiments of the invention, numerousspecific details are set forth in order to provide a more thoroughunderstanding of the invention. However, it will be apparent to one ofordinary skill in the art that the invention may be practiced withoutthese specific details. In other instances, well-known features have notbeen described in detail to avoid unnecessarily complicating thedescription.

In many systems there may be a need for a reliable mechanism forproviding critical data that survives a partial or total power down,such as a random number used in an encryption application, a number ofaccesses used to limit access to a licensed application, etc., forexample. Due to the critical nature of the critical data, the criticaldata must survive any power loss that may occur, or a power loss must beprevented. A power down may be intentionally triggered by a hacker, forexample, to tamper with the application. Therefore, tamper protectionmay be used along with a high system level effort to avoid or react to apower down. Various embodiments of computing registers that may providethe types of data mentioned above may be configured to store theircontents to a non-volatile backup storage in a non-disruptable atomictransaction each time the computing register is updated, as will bedescribed in more detail below. In this manner, the critical data valuemay be preserved across power failure events so that operation of anapplication that uses the critical data value is not compromised in theevent of normal or malicious power down events.

FIG. 1 is a functional block diagram of a portion of a system on chip(SoC) 100 that includes an embodiment of the invention. A system on chip(SoC) is described herein that includes one or more computing registers121 that are coupled to nonvolatile bitcells 122. Each bit cell mayinclude one or more ferroelectric capacitors configured to provide anon-volatile storage cell, for example. While prior art systems made useof retention latches to retain the state of flip-flops in logic modulesduring low power operation, some power is still required to retainstate. Embodiments of the present invention may use nonvolatile elementsto retain the state of flip flops while power is completely removed.Such logic elements will be referred to herein as Non-Volatile Logic(NVL).

Central processing unit (CPU) and system memory 110 may be implementedusing various known or later developed CPU and memory architecture, suchas various levels of cache and static, dynamic, and/or read only memory,for example. The CPU may be a known or later developed CPU type, such asa microprocessor, a digital signal processor, a reduced instruction setprocessor (RISC), etc., for example. Power management logic 111 maymanage one or more power domains that may be controlled to selectivelyprovide power to various sections of SoC 100 so that portions that arenot being used may be powered down to conserve power, for example.

Non-volatile memory (NVM) 112 may be implemented using various known orlater developed non-volatile technologies, such as Ferroelectric randomaccess memory (FRAM), EEPROM (electrically erasable programmable readonly memory), Flash memory, etc., for example. Ferroelectric randomaccess memory is a non-volatile memory technology with similar behaviorto DRAM (dynamic random access memory). Each individual bit can beaccessed, but unlike EEPROM does not require a special sequence to writedata nor does it require a charge pump to achieve required higherprogramming voltages. Each ferroelectric memory cell contains one ormore ferroelectric capacitors (FeCap).

While the NVM 112 may be used to store critical data that is producedwithin the computing register, such as a random number or a countervalue, storing the current critical value in non-volatile memory 112would have to be done on a regular basis to represent the actual valueand requires additional power and time. Furthermore, storing thecritical data in memory 112 via data bus 113 could be a security issue.If SoC 100 undergoes a sudden power loss which happens before write-backof the actual value to the memory, the value might be lost or corrupted.In case it is lost, a previous value could be used twice which istypically undesired. Once SoC 112 recovers from a power loss, thenadditional steps would be required to restore the critical data from NVM112.

In order to overcome the problems mentioned above, non-volatilecomputing logic 120 includes a computing register 121 that is coupled toan array of non-volatile (NV) storage cells 122 in a manner that allowsthe contents of computing register 121 to be stored directly into the NVcells 122 each time the contents of the computing register are updated.This is done in an atomic manner in response to updating register 121which means that the update sequence cannot be interrupted or disruptedby a power failure event, for example. Computing register 121 may beimplemented using a set of latches to form various types of computingfunctions, such as: an up-counter, a down-counter, an up/down counter, ashift register, a linear feedback shift register (LFSR), etc., forexample. The latches may be in the form of various known or laterdeveloped storage cells, such as: a D-flip-flop, an RS flip-flop, agated latch, sequential cells, etc., for example. The use of FRAM basedNV storage cells may reduce power consumption as compared to other typesof NV storage cells such as Flash or EEPROM, for example. The term“atomic NVL” will be used herein to refer to latches/flip-flops that arebacked up atomically in NVL each time the state logic within the atomicNVL is accessed or otherwise triggered. The term “non-atomic NVL” willbe used to refer to latches/flip-flops in which a state backup is onlydone in response to a pending power loss or controlled power down.

Atomic NVL 120 also includes fail safe power source 123 that isconfigured to provide enough energy to guarantee that the contents ofcomputing register 121 may be successfully stored in NV storage array122 each time the contents of computing register 121 is updated, even ifall other power is removed from SoC 100 either in the normal course ofoperation or with malicious intent. During normal operation, atomic NVL120 may receive power from a power supply 126 that provides power to therest of SoC 100, such as a battery, a scavenger circuit, a solar cell, aconnection to a wall outlet, etc., for example. In another embodiment,atomic NVL 120 may be powered by a separate power source VDD(NVL) fromthe rest of SoC 100, such as a second battery, scavenging resources,etc., for example. In yet another embodiment, atomic NVL 120 may beplaced in a separate power domain VDD(NVL) that is powered by a samesource as the rest of SoC 100. Switch transistors, or other types ofisolation circuitry may be used to selectively turn on and off variouspower domains within SoC 100 in response to power management logic 111,for example. Known or later developed isolation gates and/or isolationlevel shifters may be provided to prevent cross-currents at the inputsof a powered domain, caused by floating logic that is in a power domainthat is currently turned off.

Fail safe power source 123 may be in the form of a capacitor that ischarged during normal operation of NVL 120. When power is removed fromSoC 100, fail safe power supply 120 provides enough power to allow anypending update to NV storage 122 to be completed. Isolation circuitry,such as a diode or other electronic device may be provided to preventpower from fail-safe source 123 being dissipated on other circuitryoutside of atomic NVL 120 during a general power loss, for example.Write inhibit logic 124 may be provided to record when a write or otherinitialization action has been performed on computing register 121.Initial write logic 124 may be in the form of a one bit counter to allowonly one update, or in the form of a multi-bit counter to allow alimited number of write operations to initialize computing register 121.In some embodiments, computing register 121 may be addressed by CPU 110via address bus 114 and provided with an initial data value via data bus113. In other embodiments, computing register 121 may be initialized toan initial value during a production test phase, for example. In otherembodiments, computing register may be initialized to an initial valueby a reset operation, for example. The write inhibit logic may beinitialized at production test to have a defined initial state when itleaves the factory. In this manner, initialization to random state maybe avoided. Similar, a factory set initial value may be used to inhibitany writes in the field.

In this example, the state of write inhibit logic 124 is also atomicallypreserved in NV storage cells 122. In this manner, in a user applicationmode at each startup of the digital system, the sequential cell(s) ofthe initial write logic may be restored from the NVL cells 122. In userapplication mode, a write to the calculating register may be allowed aslong as the initial write logic allows it. In this case, an atomicoperation guarantees the value to the calculating register 121 is set,the write inhibit logic 124 is updated, and both the calculatingregister and write inhibit logic value are stored in the NV cells 122.

In another embodiment, write inhibit logic 124 may be omitted. In thiscase, computing register may be initialized to a particular or randomvalue during production testing, for example. In this example, furtherupdates by a write from CPU 110 or a system reset is not permitted afterthe device leaves the factory.

In this example, control logic 125 may generate various timing andcontrol signals needed for the operation of NV logic 120. Control logic125 may also control an access interface between CPU 110 and computingregister 120. During operation of SoC 100, an application being executedby CPU may read a current value from computing register 121 usingaddress bus 114 and data bus 113. The act of reading register 121 maytrigger a computation update to register 121, such as a count, a shift,etc., depending on the computation function of computation register 121.In this case, a non-interruptible atomic transaction will guarantee thatthe computation update is completed and that the results of thecomputation are correctly stored in NV cells 122. That means thatstorage in NV cells 122 is done directly whenever a new value isgenerated by a read or other type access to register 121.

Similarly, in another embodiment, computing register 121 may be coupledto a dedicated logic function such as encryption logic that isconfigured to access the contents of computation register 121, ratherthan being accessed by CPU 110. In this case, the dedicated logicfunction may trigger a computation update and an atomic operation willguarantee that the computation update is completed and that the resultsof the computation are correctly stored in NV cells 122.

When power is removed from SoC 100 and then eventually reapplied, SoC100 may go through a power up process, which may be referred to as a“reboot”. During the power up process, the computing register 121 andwrite inhibit logic 124 will be restored to the last update value thatwas stored in NV storage 122.

As described above, in various embodiments the computation register maybe triggered to perform an update computation in various manners, suchas: by reading the computation register using normal CPU read operation;by performing a write cycle to a control register; by accessing thecomputation register by dedicated functional logic; by an externaltrigger; etc., for example. Note that in both the atomic updateoperation in which the updated value of computing register is stored inNV storage 122, and in the reboot process, the contents of the computingregister need not be exposed on data bus 113. In this manner, maliciousobservation of the updated data value is prevented.

FIGS. 2 is a more detailed block diagram of an LFSR embodiment of anon-volatile computing register 221 for the SoC of FIG. 1. LinearFeedback Shift Registers (LFSR) cover various fields of application suchas pseudo random number generation used for data encryption or digitalsignal processing, for example. An LFSR is based on the principle thatthe next read-out value is determined by right-shifting the previousvalue with XORs in the feedback (Fibonacci LFSR) or shift (Galois LFSR)path. Mathematically this represents a polynomial division. In order toachieve a maximum period, primitive polynomials are selected. A seedvalue initializes the LFSR. This is typically a true random number.

As discussed above, the seed value may be initialized during productiontesting, or initialization may occur in an application mode with theassistance of an optional write inhibit logic 124 to prevent more thanone or a limited number of seed value updates.

As described above, in various embodiments LFSR computation register 221may be triggered to perform an update computation in various manners,such as: by reading the LFSR computation register using normal CPU readoperation; by performing a write cycle to a control register; byaccessing the computation register by dedicated functional logic, by anexternal trigger, etc., for example. Note that in both the atomic updateoperation in which the updated value of computing register is stored inNV storage 222, and in the reboot process, the contents of the computingregister need not be exposed on data bus 113. In this manner, maliciousobservation of the updated data value is prevented.

FIG. 3 is a more detailed block diagram of a counter embodiment of anon-volatile computing register 321 for the SoC of FIG. 1. Hardware up,down or up/down counters may be used as part of an SoC, a micro-controlunit (MCU), an application specific integrated circuit (ASIC),processors, etc., for example, to store the number of accesses tofeatures or applications, in order to limit the maximum number ofaccesses to a specific application, for example.

As discussed above, the seed value may be initialized during productiontesting, or initialization may occur in a application mode with theassistance of an optional write inhibit logic 124 to prevent more thanone or a limited number of seed value updates.

As described above, in various embodiments counter computation register321 may be triggered to perform an update computation in variousmanners, such as: by reading the counter computation register usingnormal CPU read operation; by performing a write cycle to a controlregister; by accessing the computation register by dedicated functionallogic; by an external trigger etc., for example. Note that in both theatomic update operation in which the updated value of computing registeris stored in NV storage 322, and in the reboot process, the contents ofthe computing register need not be exposed on data bus 113. In thismanner, malicious observation of the updated data value is prevented.

FIG. 4 is a plot illustrating polarization hysteresis exhibited by aferroelectric capacitor. The general operation of ferroelectric bitcells is known. When most materials are polarized, the polarizationinduced, P, is almost exactly proportional to the applied externalelectric field E; so the polarization is a linear function, referred toas dielectric polarization. In addition to being nonlinear,ferroelectric materials demonstrate a spontaneous nonzero polarizationas illustrated in FIG. 4 when the applied field E is zero. Thedistinguishing feature of ferroelectrics is that the spontaneouspolarization can be reversed by an applied electric field; thepolarization is dependent not only on the current electric field butalso on its history, yielding a hysteresis loop. The term“ferroelectric” is used to indicate the analogy to ferromagneticmaterials, which have spontaneous magnetization and also exhibithysteresis loops.

The dielectric constant of a ferroelectric capacitor is typically muchhigher than that of a linear dielectric because of the effects ofsemi-permanent electric dipoles formed in the crystal structure of theferroelectric material. When an external electric field is appliedacross a ferroelectric dielectric, the dipoles tend to align themselveswith the field direction, produced by small shifts in the positions ofatoms that result in shifts in the distributions of electronic charge inthe crystal structure. After the charge is removed, the dipoles retaintheir polarization state. Binary “0”'s and “1”'s are stored as one oftwo possible electric polarizations in each data storage cell. Forexample, in the figure a “1” may be encoded using the negative remanentpolarization 402, and a “0” may be encoded using the positive remanentpolarization 404, or vice versa.

Ferroelectric random access memories have been implemented in severalconfigurations. A one transistor, one capacitor (1T-1C) storage celldesign in a FeRAM array is similar in construction to the storage cellin widely used DRAM in that both cell types include one capacitor andone access transistor. In a DRAM cell capacitor, a linear dielectric isused, whereas in a FeRAM cell capacitor the dielectric structureincludes ferroelectric material, typically lead zirconate titanate(PZT). Due to the overhead of accessing a DRAM type array, a 1T-1C cellis less desirable for use in small arrays such as NV storage array 122.

A four capacitor, six transistor (4C-6T) cell is a common type of cellthat is easier to use in small arrays. One such cell is described inmore detail in U.S. Pat. No. 8,797,783 “Four Capacitor Nonvolatile BitCell”, Steven Craig Bartling, et al, granted Aug. 5, 2014, which isincorporated by reference herein.

FIG. 5 is a more detailed circuit diagram of a portion of a non-volatilecomputing register that may be used in FIGS. 1-3. Block 521 is a moredetailed schematic of each latch bit that is used within the computingregisters described above. In this example, each latch bit isimplemented as a retention flip-flop that allows the SoC to be placedinto a low power state in which data values are retained. Several of thesignals have an inverted version indicated by suffix “B” (referring to“bar” or /), such as RET and RETB, CLK and CLKB, etc. Each retention FFincludes a master latch 531 and a slave latch 532. Slave latch 532 isformed by inverter 533 and inverter 534. Inverter 534 includes a set oftransistors controlled by the retention signal (RET, RETB) that may usedto retain the FF state during low power sleep periods, during which apower domain VDDR remains on while a power domain VDDL is turned off.

NV bit cell 522 can be part of an NVL mini array described above, forexample. To enable data transfer between NV bit cell 522 and FF 521, twoadditional ports are provided on the slave latch 532 of each FF as shownin block 521. An input for NVL data ND is provided by gate 535 that isenabled by an NVL update signal NU. Inverter 533 is modified to allowthe inverted NVL update signal NUZ to disable the signal from masterlatch 531. When data from the NV bit cell is valid on the ND port, theNU (NVL-Update) control input is pulsed high for a cycle to write to theFF.

To save flip-flop state, the Q output 538 of each FF is connected to thedata input of NV bit cell 522 and a save signal 537 is pulsed. Asdiscussed above in more detail, the state of each latch in computationlatch 121 is saved after each computation update in an atomic manner sothat the update data is not lost in the event of a power fail. The savesignal 537 may be triggered by control logic 125 each time thecomputation latch is updated, as described above.

To restore flip-flop state, control logic 125 pulses the NU signal foreach flip-flop. During system restore, retention signal RET is held highand the slave latch is written from ND with power domain VDDL unpowered;at this point the state of the system clock CLK is a don't care. FF'smay be placed in the retention state with VDDL=0V and VDDR=VDD in orderto suppress excess power consumption. One skilled in the art can easilysee that suitably modified non-retention flops can be used in NVL basedSOC's at the expense of higher power consumption during NVL datarecovery operations.

System clock CLK may start from an inactive state once VDDL comes up andthereafter normal synchronous operation continues with updatedinformation in the FFs. Since a direct access is provided between theFFs 521 and NV array cells 522, intervention from a microcontrollerprocessing unit (CPU) is not required for NVL operations; therefore theimplementation is SoC/CPU architecture agnostic.

FIG. 6 is a functional block diagram of a portion of a system on chip(SoC) 600 that includes an embodiment of the invention. In this example,a micro-control unit (MCU) such as CPU 110, may be implemented with NVLwithin an SoC (system on a chip) and may have the ability to stop, powerdown, and power up with no loss in functionality. A system reset/rebootis not required to resume operation after power has been completelyremoved. This capability is ideal for emerging energy harvestingapplications, such as Near Field Communication (NFC), radio frequencyidentification (RFID) applications, and embedded control and monitoringsystems, for example, where the time and power cost of the reset/rebootprocess can consume much of the available energy, leaving little or noenergy for useful computation, sensing, or control functions. Though thepresent embodiment utilizes an SoC (system on chip) containing aprogrammable MCU for sequencing the SoC state machines, one of ordinaryskill in the art can see that NVL can be applied to state machines hardcoded into ordinary logic gates or ROM (read only memory), PLA(programmable logic array), or PLD (programmable logic device) basedcontrol systems, for example.

Without NVL, a chip would either have to keep all flip-flops powered inat least a low power retention state that requires a continual powersource even in standby mode, or waste energy and time rebooting afterpower-up. For energy harvesting applications, NVL is useful becausethere is no constant power source required to preserve the state offlip-flops (FFs), and even when the intermittent power source isavailable, boot-up code alone may consume all the harvested energy. Forhandheld devices with limited cooling and battery capacity, zero-leakageIC's (integrated circuits) with “instant-on” capability are ideal.

An SoC may be implemented using the atomic NVL cells as described aboveto provide the benefit of non-volatile operation. However, using atomicNVL for all logic within an SoC may be more expensive in terms of chiparea and power consumption than non-atomic NVL. Non-atomic NVL is a typeof NVL in which the state of operating latches/flip-flops is transferredto the NV arrays when a power down event has been detected, or when onlycertain power domains are powered down to reduce energy usage. In thiscase, a certain amount of time and energy is required to transfer thestate information to the NV storage. SoC 600 is an example of a mixedsystem in which atomic NVL may be used for encapsulated circuitry suchas the computing register(s) 620 discussed above and non-atomic NVL maybe used for the remaining logic such as the CPU, etc. Non-atomic NVL maybe implemented using one or more arrays 610 of FeCap (ferroelectriccapacitor) based bitcells to save state of the various flip flops 612when power is removed. Each cloud 602-604 of FFs 612 may include anassociated NVL array 610. A central non-atomic NVL controller 606controls all the arrays and their communication with FFs 612. Whilethree FF clouds 602-604 are illustrated here, SoC 600 may haveadditional, or fewer, FF clouds all controlled by NVL controller 606.This example non-atomic NVL array implementation uses 256 bitmini-arrays, but arrays may have a greater or lesser number of bits asneeded.

In SoC 600, modified retention FFs 612 include simple input and controlmodifications to allow the state of each FF to be saved in an associatedFeCap bit cell in NVL array 610 when the system is being transitioned toa power off state. When the system is restored, then the saved state istransferred from NVL array 610 back to each FF 612. In SoC 600, NVLarrays 610 and controller 606 are operated on an NVL power domainreferred to as VDDN and are switched off during regular operation. Alllogic, memory blocks 607 such as ROM (read only memory) and SRAM (staticrandom access memory), and master stage of FFs are on a logic powerdomain referred to as VDDL. FRAM (ferroelectric random access memory)arrays are directly connected to a dedicated global supply rail (VDDZ)that may be maintained at a higher fixed voltage needed for FRAM. In atypical embodiment, VDDZ is a fixed supply and VDDL can be varied aslong as VDDL remains at a lower potential than VDDZ. Note that FRAMarrays 603 may contain integrated power switches that allow the FRAMarrays to be powered down as needed. However, it can easily be seen thatFRAM arrays without internal power switches can be utilized inconjunction with power switches that are external to the FRAM array. Theslave stages of retention FFs are on a retention power domain referredto as the VDDR domain to enable regular retention in a stand-by mode ofoperation.

State info could be saved in a large centralized FRAM array, but wouldrequire more time to enter sleep mode, longer wakeup time, excessiverouting, and power costs caused by the lack of parallel access to systemFFs.

An embodiment of the invention may be included within SoC 600 to providean atomic non-volatile computing module 620 that includes a computingregister 621 directly coupled to a non-volatile storage array 622. Asdescribed in more detail above with regard to FIGS. 1-5, each time acomputation update is triggered in computation register 621, an atomicoperation will guarantee that the computation update is completed andthat the results of the computation are correctly stored in NV cells622. In some embodiments, NV storage array 610 is the same or similar tostorage arrays 610. In other embodiments, there may be a difference inthe organization or access interface, for example.

This is in contrast to prior art systems in which a state is saved to anon-volatile memory or array, such as FRAM, Flash, EEPROM, or non-atomicNVL, is only performed when a power down is in progress. In prior artsystems, a malicious attempt to hack a system by performing an incorrectpower down sequence or by causing a power failure in the system mayprevent writing back the computing register's actual data to the NVM. Inthese systems, the implementation of a failsafe power source requireshigh system level efforts. Furthermore, in prior art systems, a typicalmalicious attempt to hack the sensitive data is to manipulate the dataon the system data or address bus while it is transferred to the NVM.However, since computing register 621 is directly coupled to NV storagearray 622 and is backed up every time the computing register is updatedby an atomic operation, as described in more detail above, the sensitivedata that may be stored in computing register 621 will not bemanipulated by malicious attempts.

During normal operation, atomic NVL 620 may receive power from a powersupply 626 that provides power to the rest of SoC 600, such as abattery, a scavenger circuit, a solar cell, a connection to a walloutlet, etc., for example. In another embodiment, atomic NVL 620 may bepowered by a separate power source VDD(NVL) from the rest of SoC 600,such as a second battery, scavenging resources, etc., for example. Inyet another embodiment, atomic NVL 620 may be placed in a separate powerdomain VDD(NVL) that is powered by a same source as the rest of SoC 600.In this case, switch transistors 608 or other types of isolationcircuitry may be used to selectively turn on and off various powerdomains within SoC 600 in response to power management logic. Forexample, there may be a control voltage domain VDDN_CV for the NVLcontrol logic, a retention voltage domain VDDR, a general logic domainVDDL, and a FRAM domain VDDN_FV, for example. Known or later developedisolation gates and/or isolation level shifters may be provided toprevent cross-currents at the inputs of a powered domain, caused byfloating logic that is in a power domain that is currently turned off.

FIG. 7 is a flow chart illustrating operation of a non-volatilecomputing circuit that performs atomic backup transactions. A digitalsystem may be provided with a non-volatile computing circuit such asdescribed with regards to FIGS. 1-3, such as: an up-counter, adown-counter, an up/down counter, a shift register, a linear feedbackshift register (LFSR), etc., for example. At some point in time, aninitial value may be stored 704 in the computing circuit. As describedabove in more detail, this may be performed during production testing orduring operation in an application environment, for example. The initialvalue is copied to a non-volatile storage array as an atomictransaction.

During the course of operation, accesses 706 may be made to thecomputing circuit by a processing unit or other accessing module thatmay be coupled to the computing circuit. Each time the computing circuitis accessed, a computation may be triggered to cause an updated value tobe computed and copied into the non-volatile storage array as an atomictransaction. As discussed above in more detail, embodiments thecomputation register may be triggered to perform an update computationin various manners, such as: by reading the computation register usingnormal CPU read operation; by performing a write cycle to a controlregister; by accessing the computation register by dedicated functionallogic; by an external trigger, etc., for example.

Accessing, computing and copying to non-volatile storage may continueuntil a power failure 708 occurs. Since the contents of the computingregister are atomically copied to the non-volatile storage each time thecomputing register is triggered, nothing needs to be done to preservedata when a power failure occurs.

Once power is restored 710, the contents of the computing register maybe restored from the non-volatile storage and operation may thencontinue as if power was never lost. In another implementation,restoring of the computing register from the NVL storage 712 is part ofthe atomic transaction 706. In this implementation, the data is restoredfrom the NVL storage to the computing register each time the atomictransaction is initiated.

In some embodiments, a write inhibit circuit may be provided to preventmore than a limited number of initializations. In this case, when awrite attempt 700 is made, only the first initialization writetransaction 700 or first limited number of initialization writetransactions 700 will be permitted 704. Additional write attempts beyondthe specified limit will be inhibited 702.

In an embodiment that does not provide a write inhibit circuit, thecomputing circuit may be configured to only be initialized duringproduction testing, for example. In other embodiments that do notprovide a write inhibit circuit, write access to the computing circuitmay be controlled using software or other security measures, forexample.

Thus, embodiments of the invention may include a non-volatile computinglogic such as a LFSR or a counter in which a critical data value may becomputed and stored in NVL based flip-flops which retain the actualvalue even after a power-down. Generation of new LFSR/counter values andstorage in NVL cells is done as non-disruptable atomic operation. Evenon a sudden power loss the operation may be completed using power from asufficiently sized fail safe power supply, such as an internal supplycapacitor. Automatic recovery of the actual LFSR/counter value into theLFSR/counter flops may be performed after power up following a powerdown or power loss or as part of the atomic transaction. In this manner,increased security is provided since sensitive infrastructure such as asystem data bus is not required to reinitialize the current value.Furthermore, increased security is provided since the generation and theNV storage of a new LFSR/counter value is an atomic operation. Thisallows reduced recovery time and energy compared to a reinitializationfrom memory.

Other Embodiments

Although the invention finds particular application to microcontrollers(MCU) implemented, for example, in a System on a Chip (SoC), it alsofinds application to other forms of processors and integrated circuits.A SoC may contain one or more modules which each include custom designedfunctional circuits combined with pre-designed functional circuitsprovided by a design library, for example.

While the invention has been described with reference to illustrativeembodiments, this description is not intended to be construed in alimiting sense. Various other embodiments of the invention will beapparent to persons skilled in the art upon reference to thisdescription. For example, other portable, or mobile systems such asremote controls, access badges and fobs, smart credit/debit cards andemulators, smart phones, digital assistants, and any other now known orlater developed portable or embedded system may embody an atomicnon-volatile computing module as described herein to allow updating andstoring critical data that may be immune from attempts by hacking toreveal or corrupt the critical data. Other embodiments may use FRAMbased atomic NVL to implement portions of circuitry in order to reducepower consumption, as opposed to other NV technologies such as Flash orEEPROM, for example.

While embodiments of retention latches coupled to a nonvolatile FeCapbitcell are described herein, in another embodiment, a nonvolatile FeCapbitcell from an NVL array may be coupled to a flip-flop or latch thatdoes not include a low power retention latch. In this case, the systemwould transition between a full power state, or otherwise reduced powerstate based on reduced voltage or clock rate, and a totally off powerstate, for example. A computation update and an atomic operation willguarantee that the computation update is completed and that the resultsof the computation are correctly stored in NV cells coupled to the latchbits. When power is restored, the latches would be initialized via aninput provided by the associated NV array bitcell.

While embodiments are described herein in which the state of atomic NVLcircuits is restored in response to a power up event, in otherembodiments there may be additional or different restore events that maycause the state of the atomic NVL circuits to be restored, such as: inresponse to a reset signal or command, in response to an explicitrestore command from the CPU or other control logic, in response todoing a calculation, etc., for example.

Certain terms are used throughout the description and the claims torefer to particular system components. As one skilled in the art willappreciate, components in digital systems may be referred to bydifferent names and/or may be combined in ways not shown herein withoutdeparting from the described functionality. This document does notintend to distinguish between components that differ in name but notfunction. In the following discussion and in the claims, the terms“including” and “comprising” are used in an open-ended fashion, and thusshould be interpreted to mean “including, but not limited to . . . . ”Also, the term “couple” and derivatives thereof are intended to mean anindirect, direct, optical, and/or wireless electrical connection. Thus,if a first device couples to a second device, that connection may bethrough a direct electrical connection, through an indirect electricalconnection via other devices and connections, through an opticalelectrical connection, and/or through a wireless electrical connection.

Although method steps may be presented and described herein in asequential fashion, one or more of the steps shown and described may beomitted, repeated, performed concurrently, and/or performed in adifferent order than the order shown in the figures and/or describedherein. Accordingly, embodiments of the invention should not beconsidered limited to the specific ordering of steps shown in thefigures and/or described herein.

It is therefore contemplated that the appended claims will cover anysuch modifications of the embodiments as fall within the true scope andspirit of the invention.

What is claimed is:
 1. A digital system comprising: a calculatingregister having a plurality of latches configured to perform acalculation; a plurality of non-volatile storage cells coupled to theplurality of latches; access detection logic coupled to the calculatingregister, wherein the access detection logic is operable to initiate acalculation of a next value by the calculating register each time thecalculating register is accessed by an accessing module; and wherein theaccess detection logic is operable to cause the next value to be storedin the plurality of non-volatile storage cells at the completion of thecalculation as an atomic transaction.
 2. The digital system of claim 1,wherein the calculating register is a linear feedback shift register. 3.The digital system of claim 1, wherein the calculating register is acounter.
 4. The digital system of claim 1, further comprising a failsafepower source coupled to the calculating register and to the plurality ofnon-volatile storage cells, wherein the failsafe power source hassufficient power storage to allow the calculating register to complete acalculation and to store the resultant next value in the plurality ofnon-volatile storage cells.
 5. The digital system of claim 1, furthercomprising an accessing module coupled to access the contents of thecalculating register.
 6. The digital system of claim 1, furthercomprising initial write logic coupled to the calculating register,wherein the initial write logic is operable to prevent the calculatingregister from being written to more than a limited number of times. 7.The digital system of claim 1, wherein the non-volatile storage cellsare ferroelectric storage cells.
 8. The digital system of claim 1,further comprising control logic coupled to detect a restore event andto cause the contents of the calculating register to be restored fromthe plurality of non-volatile storage cells.
 9. The method of claim 8,wherein the restore event is a power up event.
 10. A method foroperating a digital system, the method comprising: storing an initialdata value in a computing register; and performing an atomic operationon the computing register comprising accessing a current value in thecomputing register, performing a computation on the current value toproduce a next value, and storing the next value in a non-volatile cellarray coupled to the computing register.
 11. The method of claim 10,wherein storing the initial data value is performed by writing aninitial data value into the non-volatile computing register and storingthe initial value in the non-volatile cell array as an atomic operation.12. The method of claim 10, further comprising preventing another writeto the non-volatile computing register after writing the initial value.13. The method of claim 10, further comprising preventing another writeto the non-volatile computing register after writing a limited number ofinitial values.
 14. The method of claim 10, further comprising providinga failsafe power source that has sufficient power storage to allow thecalculating register to complete a calculation and to store the resultsin the non-volatile computing register as an atomic transaction.
 15. Themethod of claim 10, further comprising detecting a restore event andcausing the contents of the computing register to be restored from thenon-volatile cell array.
 16. The method of claim 16, wherein the restoreevent is a power up event.